package hello

import (
	"context"

	v1 "demo/api/hello/v1"
	"demo/internal/dao"
	"demo/internal/model/do"
)

func (c *ControllerV1) UserGetList(ctx context.Context, req *v1.UserGetListReq) (res *v1.UserGetListRes, err error) {
	// return nil, gerror.NewCode(gcode.CodeNotImplemented)
	res = &v1.UserGetListRes{}
	err = dao.User.Ctx(ctx).Where(do.User{
		Status: req.Status,
		Age:    req.Age,
	}).Scan(&res.List)
	return
}
